#!/bin/bash
stdout=$(${program})
retval=$?

echo 1..3
if [ $retval -eq 0 ]; then
	echo "ok - Exits without error"
else
	echo "not ok - Exist with ${retval}"
fi

if [ -z "${stdout}" ]; then
	echo "not ok - no output"
else
	echo "ok - outputs data"
fi

stderr=$(echo ${testdata} | ${program} 2>&1 >/dev/null)

if [ -z ${stderr} ]; then
	echo "ok - Does not output an error message"
else
	echo "not ok - Outputs an error message"
fi
